package com.macken.wowadmin.entity;

import java.sql.ResultSet;
import java.sql.SQLException;

import org.springframework.jdbc.core.RowMapper;

public class AdminInfo {
	public int adminId;
	public int hostId;
	public String adminName;
	public String adminPass;
	public String note;
	public int getAdminId() {
		return adminId;
	}
	public void setAdminId(int adminId) {
		this.adminId = adminId;
	}
	public int getHostId() {
		return hostId;
	}
	public void setHostId(int hostId) {
		this.hostId = hostId;
	}
	public String getAdminName() {
		return adminName;
	}
	public void setAdminName(String adminName) {
		this.adminName = adminName;
	}
	public String getAdminPass() {
		return adminPass;
	}
	public void setAdminPass(String adminPass) {
		this.adminPass = adminPass;
	}
	public String getNote() {
		return note;
	}
	public void setNote(String note) {
		this.note = note;
	}
	
	public static RowMapper<AdminInfo> rowMapper=new RowMapper<AdminInfo>() {
		
		public AdminInfo mapRow(ResultSet rs, int rowNum) throws SQLException {
			// 
			AdminInfo admin=new AdminInfo();
			admin.adminId=rs.getInt("admin_id");
			admin.hostId=rs.getInt("host_id");
			admin.adminName=rs.getString("admin_name");
			admin.adminPass=rs.getString("admin_pass");
			admin.note=rs.getString("note");
			return admin;
		}
	};
}
